<!DOCTYPE html>
<html>
<head>
	<title>JSONP 实例</title>
	<meta charset="utf8">
	<script src="./jQuery.min.js"></script>	
</head>
<body>
<div id="divCustomers">
   <p id="say"></p>
   <button id="btn">申请JSON</button>
   <button onclick="ajaxcheck()">ajax</buttom>
</div>
<script>
$("#btn").click(function(){

  $.get("./jsonback.php?jsoncallback=?", function(data) {
	 	  var html = JSON.parse(data);
	 	  alert(html.word);
	    $('#say').html(html); 
   });
});
</script>

<script>
function ajaxcheck(){
   alert('点击');
   $.ajax({
      type:'GET',
      url: './jsonback.php?jsoncallback=?',
      dataType: 'text', //注意这里面的格式形式！
      success:function(msg){
         var data=JSON.parse(msg);
         alert('word'+data.word);
      }
   })
}
</script>
</body>
</html>